package com.oldroid.apps.getit.util;

import android.content.Context;
import android.content.res.Configuration;
import android.os.Build;
/**
 * An assortment of UI helpers.
 * @author Taehyun Park
 */
public class UIUtils {
	public static boolean isHoneycomb() {
		// Can use static final constants like HONEYCOMB, declared in later
		// versions of the OS since they are inlined at compile time. This is
		// guaranted behavior.
		return Build.VERSION.SDK_INT >= Build.VERSION_CODES.HONEYCOMB;
	}

	public static boolean isHoneycombTablet(Context context) {
		return isHoneycomb()
				&& (context.getResources().getConfiguration().screenLayout & Configuration.SCREENLAYOUT_SIZE_MASK) == Configuration.SCREENLAYOUT_SIZE_XLARGE;
	}
}
